/**
 ******************************* ICE *******************************
 * ========================================================================
 * Project:		icetalkdataservices
 * Package:		org.ice4apps.talk.dataservices
 * File:		IceTalkDataServiceLocator.java
 * Author: 		robin
 * Date: 		Nov 1, 2009
 * Description:	
 * ========================================================================
 * 
 */

package org.ice4apps.talk.dataservices;

import javax.naming.InitialContext;

public final class IceTalkDataServiceLocator {
    
    private static IceTalkDataServiceLocal ds = null;
    
    public static IceTalkDataServiceLocal getIceTalkDataService () throws Exception {
        if (ds == null){
            InitialContext ctx = new InitialContext();  
            ds = (IceTalkDataServiceLocal)ctx.lookup ("IceTalkDataService/local");
        }
        return ds;
    }
}
